3.1471 \(\int \frac{-2+x}{\sqrt{-3+x} (-8+x^2)} \, dx\)

Optimal. Leaf size=45 \[ \frac{\tan ^{-1}\left (\left (\sqrt{2}-1\right ) \sqrt{x-3}\right )}{\sqrt{2}}+\frac{\tan ^{-1}\left (\left (1+\sqrt{2}\right ) \sqrt{x-3}\right )}{\sqrt{2}} \]

[Out]

ArcTan[(-1 + Sqrt[2])*Sqrt[-3 + x]]/Sqrt[2] + ArcTan[(1 + Sqrt[2])*Sqrt[-3 + x]]/Sqrt[2]

________________________________________________________________________________________

Rubi [A]  time = 0.0751797, antiderivative size = 57, normalized size of antiderivative = 1.27, number of steps used = 4, number of rules used = 3, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.167, Rules used = {827, 1163, 203} \[ \frac{\tan ^{-1}\left (\frac{\sqrt{x-3}}{\sqrt{3-2 \sqrt{2}}}\right )}{\sqrt{2}}+\frac{\tan ^{-1}\left (\frac{\sqrt{x-3}}{\sqrt{3+2 \sqrt{2}}}\right )}{\sqrt{2}} \]

Warning: Unable to verify antiderivative.

[In]

Int[(-2 + x)/(Sqrt[-3 + x]*(-8 + x^2)),x]

[Out]

ArcTan[Sqrt[-3 + x]/Sqrt[3 - 2*Sqrt[2]]]/Sqrt[2] + ArcTan[Sqrt[-3 + x]/Sqrt[3 + 2*Sqrt[2]]]/Sqrt[2]

Rule 827

Int[((f_.) + (g_.)*(x_))/(Sqrt[(d_.) + (e_.)*(x_)]*((a_) + (c_.)*(x_)^2)), x_Symbol] :> Dist[2, Subst[Int[(e*f
 - d*g + g*x^2)/(c*d^2 + a*e^2 - 2*c*d*x^2 + c*x^4), x], x, Sqrt[d + e*x]], x] /; FreeQ[{a, c, d, e, f, g}, x]
 && NeQ[c*d^2 + a*e^2, 0]

Rule 1163

Int[((d_) + (e_.)*(x_)^2)/((a_) + (b_.)*(x_)^2 + (c_.)*(x_)^4), x_Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Di
st[e/2 + (2*c*d - b*e)/(2*q), Int[1/(b/2 - q/2 + c*x^2), x], x] + Dist[e/2 - (2*c*d - b*e)/(2*q), Int[1/(b/2 +
 q/2 + c*x^2), x], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && EqQ[c*d^2 - a*e^2, 0] && GtQ[b^2
 - 4*a*c, 0]

Rule 203

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTan[(Rt[b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[b, 2]), x] /;
 FreeQ[{a, b}, x] && PosQ[a/b] && (GtQ[a, 0] || GtQ[b, 0])

Rubi steps

\begin{align*} \int \frac{-2+x}{\sqrt{-3+x} \left (-8+x^2\right )} \, dx &=2 \operatorname{Subst}\left (\int \frac{1+x^2}{1+6 x^2+x^4} \, dx,x,\sqrt{-3+x}\right )\\ &=\frac{1}{2} \left (2-\sqrt{2}\right ) \operatorname{Subst}\left (\int \frac{1}{3-2 \sqrt{2}+x^2} \, dx,x,\sqrt{-3+x}\right )+\frac{1}{2} \left (2+\sqrt{2}\right ) \operatorname{Subst}\left (\int \frac{1}{3+2 \sqrt{2}+x^2} \, dx,x,\sqrt{-3+x}\right )\\ &=\frac{\tan ^{-1}\left (\frac{\sqrt{-3+x}}{\sqrt{3-2 \sqrt{2}}}\right )}{\sqrt{2}}+\frac{\tan ^{-1}\left (\frac{\sqrt{-3+x}}{\sqrt{3+2 \sqrt{2}}}\right )}{\sqrt{2}}\\ \end{align*}

Mathematica [A]  time = 0.14624, size = 69, normalized size = 1.53 \[ \frac{\left (2+\sqrt{2}\right ) \left (\tan ^{-1}\left (\sqrt{3-2 \sqrt{2}} \sqrt{x-3}\right )+\tan ^{-1}\left (\sqrt{3+2 \sqrt{2}} \sqrt{x-3}\right )\right )}{2 \sqrt{3+2 \sqrt{2}}} \]

Warning: Unable to verify antiderivative.

[In]

Integrate[(-2 + x)/(Sqrt[-3 + x]*(-8 + x^2)),x]

[Out]

((2 + Sqrt[2])*(ArcTan[Sqrt[3 - 2*Sqrt[2]]*Sqrt[-3 + x]] + ArcTan[Sqrt[3 + 2*Sqrt[2]]*Sqrt[-3 + x]]))/(2*Sqrt[
3 + 2*Sqrt[2]])

________________________________________________________________________________________

Maple [B]  time = 0.042, size = 119, normalized size = 2.6 \begin{align*}{\frac{\sqrt{2}}{2+2\,\sqrt{2}}\arctan \left ( 2\,{\frac{\sqrt{-3+x}}{2+2\,\sqrt{2}}} \right ) }+2\,{\frac{1}{2+2\,\sqrt{2}}\arctan \left ( 2\,{\frac{\sqrt{-3+x}}{2+2\,\sqrt{2}}} \right ) }-{\frac{\sqrt{2}}{-2+2\,\sqrt{2}}\arctan \left ( 2\,{\frac{\sqrt{-3+x}}{-2+2\,\sqrt{2}}} \right ) }+2\,{\frac{1}{-2+2\,\sqrt{2}}\arctan \left ( 2\,{\frac{\sqrt{-3+x}}{-2+2\,\sqrt{2}}} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-2+x)/(x^2-8)/(-3+x)^(1/2),x)

[Out]

2^(1/2)/(2+2*2^(1/2))*arctan(2*(-3+x)^(1/2)/(2+2*2^(1/2)))+2/(2+2*2^(1/2))*arctan(2*(-3+x)^(1/2)/(2+2*2^(1/2))
)-2^(1/2)/(-2+2*2^(1/2))*arctan(2*(-3+x)^(1/2)/(-2+2*2^(1/2)))+2/(-2+2*2^(1/2))*arctan(2*(-3+x)^(1/2)/(-2+2*2^
(1/2)))

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{x - 2}{{\left (x^{2} - 8\right )} \sqrt{x - 3}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2+x)/(x^2-8)/(-3+x)^(1/2),x, algorithm="maxima")

[Out]

integrate((x - 2)/((x^2 - 8)*sqrt(x - 3)), x)

________________________________________________________________________________________

Fricas [A]  time = 1.76649, size = 72, normalized size = 1.6 \begin{align*} \frac{1}{2} \, \sqrt{2} \arctan \left (\frac{\sqrt{2}{\left (x - 4\right )}}{4 \, \sqrt{x - 3}}\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2+x)/(x^2-8)/(-3+x)^(1/2),x, algorithm="fricas")

[Out]

1/2*sqrt(2)*arctan(1/4*sqrt(2)*(x - 4)/sqrt(x - 3))

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{x - 2}{\sqrt{x - 3} \left (x^{2} - 8\right )}\, dx \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2+x)/(x**2-8)/(-3+x)**(1/2),x)

[Out]

Integral((x - 2)/(sqrt(x - 3)*(x**2 - 8)), x)

________________________________________________________________________________________

Giac [A]  time = 1.25149, size = 31, normalized size = 0.69 \begin{align*} \frac{1}{4} \, \sqrt{2}{\left (\pi + 2 \, \arctan \left (\frac{\sqrt{2}{\left (x - 4\right )}}{4 \, \sqrt{x - 3}}\right )\right )} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2+x)/(x^2-8)/(-3+x)^(1/2),x, algorithm="giac")

[Out]

1/4*sqrt(2)*(pi + 2*arctan(1/4*sqrt(2)*(x - 4)/sqrt(x - 3)))